package com.student.model;

import java.sql.Timestamp;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * Medicare entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "Medicare", schema = "dbo", catalog = "StudentManager")
public class Medicare implements java.io.Serializable {

	// Fields

	private Long medicareId;
	private Student student;
	private Double medicareFee;
	private Timestamp insureDate;
	private Boolean isInsure;
	private String refuseInsureReason;

	// Constructors

	/** default constructor */
	public Medicare() {
	}

	// Property accessors
	@Id
	@Column(name = "Medicare_id", unique = true, nullable = false, precision = 18, scale = 0)
	@GeneratedValue
	public Long getMedicareId() {
		return this.medicareId;
	}

	public void setMedicareId(Long medicareId) {
		this.medicareId = medicareId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "Student_id")
	public Student getStudent() {
		return this.student;
	}

	public void setStudent(Student student) {
		this.student = student;
	}

	@Column(name = "Medicare_Fee", nullable = false, scale = 4)
	public Double getMedicareFee() {
		return this.medicareFee;
	}

	public void setMedicareFee(Double medicareFee) {
		this.medicareFee = medicareFee;
	}

	@Column(name = "Insure_Date", nullable = false, length = 23)
	public Timestamp getInsureDate() {
		return this.insureDate;
	}

	public void setInsureDate(Timestamp insureDate) {
		this.insureDate = insureDate;
	}

	@Column(name = "Is_Insure", nullable = false)
	public Boolean getIsInsure() {
		return this.isInsure;
	}

	public void setIsInsure(Boolean isInsure) {
		this.isInsure = isInsure;
	}

	@Column(name = "Refuse_Insure_Reason")
	public String getRefuseInsureReason() {
		return this.refuseInsureReason;
	}

	public void setRefuseInsureReason(String refuseInsureReason) {
		this.refuseInsureReason = refuseInsureReason;
	}

}